package com.payment.controller;


import com.payment.request.TransRequest;
import com.payment.service.IPayService;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.web.bind.annotation.*;

@RestController
@RequestMapping("/pay/")
public class PayController{

    @Autowired
    private IPayService payService;

    @PostMapping("pay")
    public String pay(@RequestBody TransRequest transRequest) {
        payService.pay(transRequest);
        return "SUCCESS";
    }
}
